<?php

namespace App\Http\Requests\OperationManagement;

use Illuminate\Foundation\Http\FormRequest;
use App\Http\Requests\BaseRequest;

class SanitationDataRequest extends BaseRequest
{
    /**
     * Determine if the user is authorized to make this request.
     *
     * @return bool
     */
    public function authorize()
    {
        return true;
    }

    /**
     * Get the validation rules that apply to the request.
     *
     * @return array
     */
    public function rules()
    {
        return [
            'nodeID' => 'required|integer',
        ];
    }

    public function messages() 
    {
        return [
            'nodeID.required' => '路口编号不能为空',
            'nodeID.integer' => '路口编号只能填写数字',
        ];
    }
}
